cmake_minimum_required(VERSION 3.12)
project(698SP_CL)

set(Demo_VERSION_MAJOR 1)
set(Demo_VERSION_MINOR 0)
set(CMAKE_CXX_STANDARD 14)
aux_source_directory(. SOURCE)
set(CMAKE_INCLUDE_CURRENT_DIR ON)
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTOUIC ON)
set(CMAKE_AUTORCC ON)
set(CMAKE_PREFIX_PATH D:/Qt5.13x86/5.13.2/mingw73_64)
find_package(Qt5Widgets)
find_package(Qt5Core)
find_package(Qt5Gui)
find_package(Qt5Sql)
set(UI_FILES)
set(RC_FILES)
set(QRC_FILES)
set(QRC_SOURCE_FILES logo.qrc)
qt5_add_resources(QRC_FILES ${QRC_SOURCE_FILES})
file(GLOB SourceFiles logo.rc)

#set(CMAKE_EXE_LINKER_FLAGS "-static-libgcc -static-libstdc++")
#set(CMAKE_EXE_LINKER_FLAGS -Wl,-subsystem,windows)
#set(CMAKE_EXE_LINKER_FLAGS -mwindows)
link_libraries(ws2_32)
add_executable(698SP_CL ${SOURCE} ${QRC_FILES} ${SourceFiles})

add_subdirectory(BasicExcel)
add_subdirectory(XMLFile)
add_subdirectory(ONLINE)

target_link_libraries(698SP_CL ws2_32 Qt5::Widgets BasicExcel_ XML ONLINE_)

qt5_use_modules(698SP_CL Core Widgets Gui Sql)
